3.2.45 \(\int \frac {\sqrt {c+d \sec (e+f x)}}{a+a \sec (e+f x)} \, dx\) [145]

3.2.45.1 Optimal result
3.2.45.2 Mathematica [A] (verified)
3.2.45.3 Rubi [A] (verified)
3.2.45.4 Maple [A] (verified)
3.2.45.5 Fricas [F]
3.2.45.6 Sympy [F]
3.2.45.7 Maxima [F]
3.2.45.8 Giac [F]
3.2.45.9 Mupad [F(-1)]

3.2.45.1 Optimal result

Integrand size = 27, antiderivative size = 225 \[ \int \frac {\sqrt {c+d \sec (e+f x)}}{a+a \sec (e+f x)} \, dx=-\frac {2 \cot (e+f x) \operatorname {EllipticPi}\left (\frac {c}{c+d},\arcsin \left (\frac {\sqrt {c+d}}{\sqrt {c+d \sec (e+f x)}}\right ),\frac {c-d}{c+d}\right ) \sqrt {-\frac {d (1-\sec (e+f x))}{c+d \sec (e+f x)}} \sqrt {\frac {d (1+\sec (e+f x))}{c+d \sec (e+f x)}} (c+d \sec (e+f x))}{a \sqrt {c+d} f}-\frac {E\left (\arcsin \left (\frac {\tan (e+f x)}{1+\sec (e+f x)}\right )|\frac {c-d}{c+d}\right ) \sqrt {\frac {1}{1+\sec (e+f x)}} \sqrt {c+d \sec (e+f x)}}{a f \sqrt {\frac {c+d \sec (e+f x)}{(c+d) (1+\sec (e+f x))}}} \]

output
-2*cot(f*x+e)*EllipticPi((c+d)^(1/2)/(c+d*sec(f*x+e))^(1/2),c/(c+d),((c-d) 
/(c+d))^(1/2))*(c+d*sec(f*x+e))*(-d*(1-sec(f*x+e))/(c+d*sec(f*x+e)))^(1/2) 
*(d*(1+sec(f*x+e))/(c+d*sec(f*x+e)))^(1/2)/a/f/(c+d)^(1/2)-EllipticE(tan(f 
*x+e)/(1+sec(f*x+e)),((c-d)/(c+d))^(1/2))*(1/(1+sec(f*x+e)))^(1/2)*(c+d*se 
c(f*x+e))^(1/2)/a/f/((c+d*sec(f*x+e))/(c+d)/(1+sec(f*x+e)))^(1/2)
 
3.2.45.2 Mathematica [A] (verified)

Time = 7.53 (sec) , antiderivative size = 178, normalized size of antiderivative = 0.79 \[ \int \frac {\sqrt {c+d \sec (e+f x)}}{a+a \sec (e+f x)} \, dx=-\frac {4 \cos ^4\left (\frac {1}{2} (e+f x)\right ) \left ((c+d) E\left (\arcsin \left (\tan \left (\frac {1}{2} (e+f x)\right )\right )|\frac {c-d}{c+d}\right )+2 (c-d) \operatorname {EllipticF}\left (\arcsin \left (\tan \left (\frac {1}{2} (e+f x)\right )\right ),\frac {c-d}{c+d}\right )-4 c \operatorname {EllipticPi}\left (-1,\arcsin \left (\tan \left (\frac {1}{2} (e+f x)\right )\right ),\frac {c-d}{c+d}\right )\right ) \sqrt {\frac {1}{1+\sec (e+f x)}} \sqrt {c+d \sec (e+f x)}}{a (c+d) f (1+\cos (e+f x))^2 \sqrt {\frac {d+c \cos (e+f x)}{(c+d) (1+\cos (e+f x))}}} \]

input
Integrate[Sqrt[c + d*Sec[e + f*x]]/(a + a*Sec[e + f*x]),x]
 
output
(-4*Cos[(e + f*x)/2]^4*((c + d)*EllipticE[ArcSin[Tan[(e + f*x)/2]], (c - d 
)/(c + d)] + 2*(c - d)*EllipticF[ArcSin[Tan[(e + f*x)/2]], (c - d)/(c + d) 
] - 4*c*EllipticPi[-1, ArcSin[Tan[(e + f*x)/2]], (c - d)/(c + d)])*Sqrt[(1 
 + Sec[e + f*x])^(-1)]*Sqrt[c + d*Sec[e + f*x]])/(a*(c + d)*f*(1 + Cos[e + 
 f*x])^2*Sqrt[(d + c*Cos[e + f*x])/((c + d)*(1 + Cos[e + f*x]))])
 
3.2.45.3 Rubi [A] (verified)

Time = 0.64 (sec) , antiderivative size = 225, normalized size of antiderivative = 1.00, number of steps used = 5, number of rules used = 5, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.185, Rules used = {3042, 4413, 3042, 4267, 4456}

Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.

\(\displaystyle \int \frac {\sqrt {c+d \sec (e+f x)}}{a \sec (e+f x)+a} \, dx\)

\(\Big \downarrow \) 3042

\(\displaystyle \int \frac {\sqrt {c+d \csc \left (e+f x+\frac {\pi }{2}\right )}}{a \csc \left (e+f x+\frac {\pi }{2}\right )+a}dx\)

\(\Big \downarrow \) 4413

\(\displaystyle \frac {\int \sqrt {c+d \sec (e+f x)}dx}{a}-\int \frac {\sec (e+f x) \sqrt {c+d \sec (e+f x)}}{\sec (e+f x) a+a}dx\)

\(\Big \downarrow \) 3042

\(\displaystyle \frac {\int \sqrt {c+d \csc \left (e+f x+\frac {\pi }{2}\right )}dx}{a}-\int \frac {\csc \left (e+f x+\frac {\pi }{2}\right ) \sqrt {c+d \csc \left (e+f x+\frac {\pi }{2}\right )}}{\csc \left (e+f x+\frac {\pi }{2}\right ) a+a}dx\)

\(\Big \downarrow \) 4267

\(\displaystyle -\int \frac {\csc \left (e+f x+\frac {\pi }{2}\right ) \sqrt {c+d \csc \left (e+f x+\frac {\pi }{2}\right )}}{\csc \left (e+f x+\frac {\pi }{2}\right ) a+a}dx-\frac {2 \cot (e+f x) \sqrt {-\frac {d (1-\sec (e+f x))}{c+d \sec (e+f x)}} \sqrt {\frac {d (\sec (e+f x)+1)}{c+d \sec (e+f x)}} (c+d \sec (e+f x)) \operatorname {EllipticPi}\left (\frac {c}{c+d},\arcsin \left (\frac {\sqrt {c+d}}{\sqrt {c+d \sec (e+f x)}}\right ),\frac {c-d}{c+d}\right )}{a f \sqrt {c+d}}\)

\(\Big \downarrow \) 4456

\(\displaystyle -\frac {2 \cot (e+f x) \sqrt {-\frac {d (1-\sec (e+f x))}{c+d \sec (e+f x)}} \sqrt {\frac {d (\sec (e+f x)+1)}{c+d \sec (e+f x)}} (c+d \sec (e+f x)) \operatorname {EllipticPi}\left (\frac {c}{c+d},\arcsin \left (\frac {\sqrt {c+d}}{\sqrt {c+d \sec (e+f x)}}\right ),\frac {c-d}{c+d}\right )}{a f \sqrt {c+d}}-\frac {\sqrt {\frac {1}{\sec (e+f x)+1}} \sqrt {c+d \sec (e+f x)} E\left (\arcsin \left (\frac {\tan (e+f x)}{\sec (e+f x)+1}\right )|\frac {c-d}{c+d}\right )}{a f \sqrt {\frac {c+d \sec (e+f x)}{(c+d) (\sec (e+f x)+1)}}}\)

input
Int[Sqrt[c + d*Sec[e + f*x]]/(a + a*Sec[e + f*x]),x]
 
output
(-2*Cot[e + f*x]*EllipticPi[c/(c + d), ArcSin[Sqrt[c + d]/Sqrt[c + d*Sec[e 
 + f*x]]], (c - d)/(c + d)]*Sqrt[-((d*(1 - Sec[e + f*x]))/(c + d*Sec[e + f 
*x]))]*Sqrt[(d*(1 + Sec[e + f*x]))/(c + d*Sec[e + f*x])]*(c + d*Sec[e + f* 
x]))/(a*Sqrt[c + d]*f) - (EllipticE[ArcSin[Tan[e + f*x]/(1 + Sec[e + f*x]) 
], (c - d)/(c + d)]*Sqrt[(1 + Sec[e + f*x])^(-1)]*Sqrt[c + d*Sec[e + f*x]] 
)/(a*f*Sqrt[(c + d*Sec[e + f*x])/((c + d)*(1 + Sec[e + f*x]))])
 

3.2.45.3.1 Defintions of rubi rules used

rule 3042
Int[u_, x_Symbol] :> Int[DeactivateTrig[u, x], x] /; FunctionOfTrigOfLinear 
Q[u, x]
 

rule 4267
Int[Sqrt[csc[(c_.) + (d_.)*(x_)]*(b_.) + (a_)], x_Symbol] :> Simp[2*((a + b 
*Csc[c + d*x])/(d*Rt[a + b, 2]*Cot[c + d*x]))*Sqrt[b*((1 + Csc[c + d*x])/(a 
 + b*Csc[c + d*x]))]*Sqrt[(-b)*((1 - Csc[c + d*x])/(a + b*Csc[c + d*x]))]*E 
llipticPi[a/(a + b), ArcSin[Rt[a + b, 2]/Sqrt[a + b*Csc[c + d*x]]], (a - b) 
/(a + b)], x] /; FreeQ[{a, b, c, d}, x] && NeQ[a^2 - b^2, 0]
 

rule 4413
Int[Sqrt[csc[(e_.) + (f_.)*(x_)]*(b_.) + (a_)]/(csc[(e_.) + (f_.)*(x_)]*(d_ 
.) + (c_)), x_Symbol] :> Simp[1/c   Int[Sqrt[a + b*Csc[e + f*x]], x], x] - 
Simp[d/c   Int[Csc[e + f*x]*(Sqrt[a + b*Csc[e + f*x]]/(c + d*Csc[e + f*x])) 
, x], x] /; FreeQ[{a, b, c, d, e, f}, x] && NeQ[b*c - a*d, 0] && (EqQ[a^2 - 
 b^2, 0] || EqQ[c^2 - d^2, 0])
 

rule 4456
Int[(csc[(e_.) + (f_.)*(x_)]*Sqrt[csc[(e_.) + (f_.)*(x_)]*(b_.) + (a_)])/(c 
sc[(e_.) + (f_.)*(x_)]*(d_.) + (c_)), x_Symbol] :> Simp[(-Sqrt[a + b*Csc[e 
+ f*x]])*(Sqrt[c/(c + d*Csc[e + f*x])]/(d*f*Sqrt[c*d*((a + b*Csc[e + f*x])/ 
((b*c + a*d)*(c + d*Csc[e + f*x])))]))*EllipticE[ArcSin[c*(Cot[e + f*x]/(c 
+ d*Csc[e + f*x]))], -(b*c - a*d)/(b*c + a*d)], x] /; FreeQ[{a, b, c, d, e, 
 f}, x] && NeQ[b*c - a*d, 0] && NeQ[a^2 - b^2, 0] && EqQ[c^2 - d^2, 0]
 
3.2.45.4 Maple [A] (verified)

Time = 5.05 (sec) , antiderivative size = 247, normalized size of antiderivative = 1.10

method result size
default \(\frac {\left (\cos \left (f x +e \right )+1\right ) \left (2 \operatorname {EllipticF}\left (\cot \left (f x +e \right )-\csc \left (f x +e \right ), \sqrt {\frac {c -d}{c +d}}\right ) c -2 \operatorname {EllipticF}\left (\cot \left (f x +e \right )-\csc \left (f x +e \right ), \sqrt {\frac {c -d}{c +d}}\right ) d +c \operatorname {EllipticE}\left (\cot \left (f x +e \right )-\csc \left (f x +e \right ), \sqrt {\frac {c -d}{c +d}}\right )+d \operatorname {EllipticE}\left (\cot \left (f x +e \right )-\csc \left (f x +e \right ), \sqrt {\frac {c -d}{c +d}}\right )-4 c \operatorname {EllipticPi}\left (\cot \left (f x +e \right )-\csc \left (f x +e \right ), -1, \sqrt {\frac {c -d}{c +d}}\right )\right ) \sqrt {\frac {d +c \cos \left (f x +e \right )}{\left (c +d \right ) \left (\cos \left (f x +e \right )+1\right )}}\, \sqrt {\frac {\cos \left (f x +e \right )}{\cos \left (f x +e \right )+1}}\, \sqrt {c +d \sec \left (f x +e \right )}}{a f \left (d +c \cos \left (f x +e \right )\right )}\) \(247\)

input
int((c+d*sec(f*x+e))^(1/2)/(a+a*sec(f*x+e)),x,method=_RETURNVERBOSE)
 
output
1/a/f*(cos(f*x+e)+1)*(2*EllipticF(cot(f*x+e)-csc(f*x+e),((c-d)/(c+d))^(1/2 
))*c-2*EllipticF(cot(f*x+e)-csc(f*x+e),((c-d)/(c+d))^(1/2))*d+c*EllipticE( 
cot(f*x+e)-csc(f*x+e),((c-d)/(c+d))^(1/2))+d*EllipticE(cot(f*x+e)-csc(f*x+ 
e),((c-d)/(c+d))^(1/2))-4*c*EllipticPi(cot(f*x+e)-csc(f*x+e),-1,((c-d)/(c+ 
d))^(1/2)))*(1/(c+d)*(d+c*cos(f*x+e))/(cos(f*x+e)+1))^(1/2)*(cos(f*x+e)/(c 
os(f*x+e)+1))^(1/2)*(c+d*sec(f*x+e))^(1/2)/(d+c*cos(f*x+e))
 
3.2.45.5 Fricas [F]

\[ \int \frac {\sqrt {c+d \sec (e+f x)}}{a+a \sec (e+f x)} \, dx=\int { \frac {\sqrt {d \sec \left (f x + e\right ) + c}}{a \sec \left (f x + e\right ) + a} \,d x } \]

input
integrate((c+d*sec(f*x+e))^(1/2)/(a+a*sec(f*x+e)),x, algorithm="fricas")
 
output
integral(sqrt(d*sec(f*x + e) + c)/(a*sec(f*x + e) + a), x)
 
3.2.45.6 Sympy [F]

\[ \int \frac {\sqrt {c+d \sec (e+f x)}}{a+a \sec (e+f x)} \, dx=\frac {\int \frac {\sqrt {c + d \sec {\left (e + f x \right )}}}{\sec {\left (e + f x \right )} + 1}\, dx}{a} \]

input
integrate((c+d*sec(f*x+e))**(1/2)/(a+a*sec(f*x+e)),x)
 
output
Integral(sqrt(c + d*sec(e + f*x))/(sec(e + f*x) + 1), x)/a
 
3.2.45.7 Maxima [F]

\[ \int \frac {\sqrt {c+d \sec (e+f x)}}{a+a \sec (e+f x)} \, dx=\int { \frac {\sqrt {d \sec \left (f x + e\right ) + c}}{a \sec \left (f x + e\right ) + a} \,d x } \]

input
integrate((c+d*sec(f*x+e))^(1/2)/(a+a*sec(f*x+e)),x, algorithm="maxima")
 
output
integrate(sqrt(d*sec(f*x + e) + c)/(a*sec(f*x + e) + a), x)
 
3.2.45.8 Giac [F]

\[ \int \frac {\sqrt {c+d \sec (e+f x)}}{a+a \sec (e+f x)} \, dx=\int { \frac {\sqrt {d \sec \left (f x + e\right ) + c}}{a \sec \left (f x + e\right ) + a} \,d x } \]

input
integrate((c+d*sec(f*x+e))^(1/2)/(a+a*sec(f*x+e)),x, algorithm="giac")
 
output
integrate(sqrt(d*sec(f*x + e) + c)/(a*sec(f*x + e) + a), x)
 
3.2.45.9 Mupad [F(-1)]

Timed out. \[ \int \frac {\sqrt {c+d \sec (e+f x)}}{a+a \sec (e+f x)} \, dx=\int \frac {\sqrt {c+\frac {d}{\cos \left (e+f\,x\right )}}}{a+\frac {a}{\cos \left (e+f\,x\right )}} \,d x \]

input
int((c + d/cos(e + f*x))^(1/2)/(a + a/cos(e + f*x)),x)
 
output
int((c + d/cos(e + f*x))^(1/2)/(a + a/cos(e + f*x)), x)